import { MockMethod } from "vite-plugin-mock"

export default [
  {
    url: "/dev-api/gateway",
    timeout: 2000,
    method: "post",
    response: () => {
      return {
        "code": 20000,
        "message": "获取数据成功",
        "data": {
          "count": 3, // 总记录数
          "results": [{
            "id": 1,
            "create_time": "2024-09-16T15:10:51.970886+08:00",
            "update_time": "2024-09-16T15:10:51.970886+08:00",
            "uuid": "gateway1",
            "alias": "网关1",
            "online": true,
            "memo": "正在施工",
            "room": 2
          },
          {
            "id": 2,
            "create_time": "2024-09-16T15:11:40.880684+08:00",
            "update_time": "2024-09-16T15:11:40.880684+08:00",
            "uuid": "gateway2",
            "alias": "网关2",
            "online": false,
            "memo": "正在调试",
            "room": 2
          },
          {
            "id": 3,
            "create_time": "2024-09-16T15:12:13.321539+08:00",
            "update_time": "2024-09-16T15:12:13.321539+08:00",
            "uuid": "gateway3",
            "alias": "网关3",
            "online": true,
            "memo": "需要维修",
            "room": 3
          }]
        }
      }
    }
  },
] as MockMethod[]